import numpy as np
import matplotlib.pyplot as plt

a = np.loadtxt('sum_fft.txt')

n = 132000
#fourier = np.fft.fft(angles)
timestep = 0.01 # in ps
#freq = np.fft.fftfreq(n, d=timestep)

#a_re = np.reshape(a,(n,int(len(a)/n)),order='F')
#a_sum = np.sum(a_re,axis=1)

xf1 = np.linspace(0.0, 1.0//(2.0*timestep), n//2)*4.1357
yf1 = 2.0/n * np.abs(a[:n//2])

plt.plot(xf1[1:],yf1[1:]/86)
plt.show()
